//
//  cinemaViewCell.m
//  movie
//
//  Created by 李丹阳 on 15/7/22.
//  Copyright (c) 2015年 李丹阳. All rights reserved.
//

#import "cinemaViewCell.h"

@implementation cinemaViewCell

- (void)awakeFromNib {
    // Initialization code

}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (void)setModal:(cinemaModal *)modal{
    _modal = modal;
    [self setNeedsLayout];
}

- (void)layoutSubviews{
    [super layoutSubviews];
    _name.text = _modal.name;
    _address.text = _modal.address;
    _grade.text = _modal.grade;
    _lowPrice.text = [NSString stringWithFormat:@"￥ %@",_modal.lowPrice];
    if ([_modal.isSeatSupport  isEqual: @"0"] ) {
        _isSeatSupport.hidden = YES;
    }
    else{
        _isSeatSupport.hidden = NO;
    }

    if ([_modal.isCouponSupport  isEqual: @"0"]) {
        _isCouponSupport.hidden = YES;
    }
    else{
        _isCouponSupport.hidden = NO;
    }
    
}

@end
